/**
 * 登录服务
 * 
 * @author lianchao
 */
// 创建登录模块
var jobServiceApp = angular.module("jobServiceApp", [ "commonApp" ]);

// 创建登录服务
jobServiceApp.service("jobService", [
		"commonService",
		function(commonService) {
			
			/**
			 * 新增任务
			 */
			this.add = function(params, sback, eback) {
				commonService.call("tsp/job/add", params, sback, eback);
			}
			
			/**
			 * 查询任务
			 */
			this.update = function(params, sback, eback) {
				commonService.call("tsp/job/update", params, sback, eback);
			}
			
			/**
			 * 查询任务
			 */
			this.removeList = function(params, sback, eback) {
				commonService.call("tsp/job/deleteList", params, sback, eback);
			}
			
			/**
			 * 删除任务
			 */
			this.removeJobDetail = function(params, sback, eback) {
				commonService.call("tsp/job/deleteJobdetailList", params, sback, eback);
			}
			
			
			/**
			 * 暂停任务
			 */
			this.pause = function(params, sback, eback) {
				commonService.call("tsp/job/pause", params, sback, eback);
			}
			
			/**
			 * 唤醒任务
			 */
			this.resume = function(params, sback, eback) {
				commonService.call("tsp/job/resume", params, sback, eback);
			}
			
			/**
			 * 清空子任务
			 */
			this.query = function(params, sback, eback) {
				commonService.call("tsp/job/query", params, sback, eback);
			}
			
			/**
			 * 清空死任务
			 */
			this.queryPage = function(params, sback, eback) {
				commonService.call("tsp/job/queryPage", params, sback, eback);
			}
			
		}
]);